package edu.zut.cs.software.teach.Base.service;

import java.io.Serializable;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

//import org.springframework.data.domain.Page;
//import org.springframework.data.domain.Pageable;



import edu.zut.cs.software.teach.Base.domain.BaseEntity;
/**
 * 
 * @author Wzhixin,liushun
 *
 * @param <PK>
 * @param <T>
 */

public interface GenericManager<PK extends Serializable, T extends BaseEntity<PK>> {
	/**
	 * 
	 * @param id
	 * @return
	 */
    T findById(PK smsId);
	
	public void deleteId(PK smsId);

	public void deleteAll();
	
	public Iterable<T> findAll();
	
	public Page<T> findAll(Pageable page);
	
	public Iterable<T> save(Iterable<T> entities);
	
	public T save(T entity);

	public long count();
}
